package com.foreknow.demo1;

public class TestStudent {
    public static void main(String[] args) {
        Student s1 = new Student();
        //1. 调用set方法给s1对象的属性赋值
        s1.setAge(12);
        s1.setName("tom");
        //2. 获取到对象的属性值
        int age = s1.getAge();
        String name = s1.getName();
        System.out.println(age);
        System.out.println(name);
        Student s2 = new Student();
        s2.setAge(13);
        System.out.println(s2.getAge());
        Student s3 = new Student();
        Student s4 = new Student();
    }
}
